<template>
  <div class="wrapper">
    <swiper :options="swiperOption">
      <!-- slides -->
      <swiper-slide v-for="item in swiperList" :key="item.id">
        <img class="swiper-img" :src="item.imgUrl" alt="去哪儿门票">
      </swiper-slide>
      <!-- Optional controls -->
      <div class="swiper-pagination"  slot="pagination"></div>
    </swiper>
  </div>
</template>

<script>
export default {
  name: 'HomeSwiper',
  data () {
    return {
      swiperOption: {
        pagination: '.swiper-pagination',
        loop: true
      },
      swiperList: [{
        id: '0001',
        imgUrl: 'http://img1.qunarzz.com/piao/fusion/1901/28/e1bbc39303a94c02.jpg_750x200_86d44a7f.jpg'
      }, {
        id: '0002',
        imgUrl: '"http://img1.qunarzz.com/piao/fusion/1812/d6/daa880b254940402.jpg_750x200_b114308a.jpg'
      }]
    }
  }
}
</script>

<style lang="stylus" scoped>
  .wrapper
    overflow hidden;
    width 100%;
    height 0;
    padding-bottom 26.7%;
    background #eee;
    .swiper-img
       width 100%;
</style>
